package com.sx.medicinecard.entity;

import cn.afterturn.easypoi.excel.annotation.Excel;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;

import java.math.BigDecimal;
import java.util.Date;

@Data
@TableName(value = "sx_order_info")
public class SxOrderInfo extends Model<SxOrderInfo> {
    /**
     * 订单id
     */
    @TableId(value = "order_id")
    private String orderId;
    /**
     * 用户id
     */
    @TableField(value = "user_id")
    private String userId;
    /**
     * 用户id
     */
    @TableField(value = "phone_no")
    @Excel(name = "用户手机号", orderNum = "1", width = 20)
    private String phoneNo;
    /**
     * 权益id
     */
    @TableField(value = "equity_id")
    private String equityId;
    /**
     * 荷叶权益卡id
     */
    @TableField(value = "heye_equity_card_id")
    @Excel(name = "权益id", orderNum = "2", width = 20)
    private String heyeEquityCardId;
    /**
     * 支付类型（0-支付宝，1-微信）
     */
    @TableField(value = "pay_type")
    @Excel(name = "付款方式", replace = {"支付宝_0", "微信_1"}, orderNum = "9", width = 20)
    private String payType;
    /**
     * 签约id
     */
    @TableField(value = "sign_id")
    private String signId;
    /**
     * 源客订单号
     */
    @TableField(value = "yuanke_order_no")
    @Excel(name = "商户订单号", orderNum = "3", width = 20)
    private String yuankeOrderNo;
    /**
     * 支付流水号
     */
    @TableField(value = "pay_serial_number")
    @Excel(name = "流水号", orderNum = "4", width = 20)
    private String paySerialNumber;
    /**
     * 订单状态  0-未支付 1-已支付
     */
    @TableField(value = "order_status")
    @Excel(name = "支付状态", replace = {"未支付_0", "已支付_1"}, orderNum = "8", width = 20)
    private String orderStatus;
    /**
     * 支付金额
     */
    @TableField(value = "pay_amount")
    @Excel(name = "支付金额", orderNum = "5", width = 20)
    private BigDecimal payAmount;
    /**
     * 支付方式
     */
    @TableField(value = "pay_way")
    private String payWay;
    /**
     * 支付期数
     */
    @TableField(value = "pay_stage")
    private String payStage;
    /**
     * 返回消息体
     */
    @TableField(value = "body")
    private String body;
    /**
     * 退款状态 0-未退款，1-退款中，2-已退款
     */
    @TableField(value = "refund_status")
    @Excel(name = "退款状态", replace = {"未退款_0", "退款中_1", "已退款_2"}, orderNum = "9", width = 20)
    private String refundStatus;
    /**
     * 发送短信状态（0-未发送，1-已发送）
     */
    @TableField(value = "send_state")
    private String sendState;
    /**
     * 来源
     */
    @TableField(value = "source")
    private String source;
    /**
     * 创建时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    @TableField(value = "create_time")
    @Excel(name = "时间", format = "yyyy-MM-dd HH:mm:ss", orderNum = "10", width = 20)
    private Date createTime;
    /**
     * 更新时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    @TableField(value = "update_time")
    private Date updateTime;

    /**
     * 支付时间
     */
    @TableField(exist = false)
    private String payTime;

    /**
     * 会员类型（0-月付，1-年付）
     */
    @TableField(value = "vip_type")
    @Excel(name = "会员类型", replace = {"月付_0", "年付_1"}, width = 20)
    private String vipType;
    /**
     * 阿里帐号ID
     */
    @TableField(value = "ali_account_id")
    private String aliAccountId;

    /**
     * 渠道编码
     */
    @TableField(value = "channel_code")
    private String channelCode;
    /**
     * 是否投诉
     */
    @TableField(value = "is_complaint")
    private String isComplaint;

    @TableField(value = "jzt_vip_id")
    private String jztVipId;

    @TableField(value = "jzt_equity_id")
    private String jztEquityId;

    private String buyerOpenId;
}

